﻿namespace CKQDJK {
	using System;
	using SuperORM.Attributes;
	using System.ComponentModel;
	
	
	/// <summary>参数表</summary>
	[Object("参数表", "CKQDJK", "参数表")]
	[Browsable(true)]
	[DisplayName("参数表")]
	[ReadOnly(false)]
	[Serializable()]
	public class 参数表 : SuperORM.BusinessObject {
		
		/// <summary>内部变量：发证机关编码</summary>
		private string m_发证机关编码;
		
		/// <summary>标示属性发证机关编码是否为空的字段。</summary>
		private bool m_Is发证机关编码Null = true;
		
		/// <summary>内部变量：发证机关名称</summary>
		private string m_发证机关名称;
		
		/// <summary>标示属性发证机关名称是否为空的字段。</summary>
		private bool m_Is发证机关名称Null = true;
		
		/// <summary>内部变量：BSM</summary>
		private int m_BSM;
		
		/// <summary>标示属性BSM是否为空的字段。</summary>
		private bool m_IsBSMNull = true;
		
		public static string TypeID = "CKQDJK.参数表";
		
		/// <summary>属性发证机关编码</summary>
		[Member("发证机关编码", "发证机关编码", "System.String", 12, false, false, "发证机关编码")]
		[Browsable(true)]
		[DisplayName("发证机关编码")]
		[ReadOnly(false)]
		public string 发证机关编码 {
			get {
				return this.m_发证机关编码;
			}
			set {
				this.m_发证机关编码 = value;
				this.m_Is发证机关编码Null = false;
			}
		}
		
		/// <summary>属性发证机关名称</summary>
		[Member("发证机关名称", "发证机关名称", "System.String", 80, false, false, "发证机关名称")]
		[Browsable(true)]
		[DisplayName("发证机关名称")]
		[ReadOnly(false)]
		public string 发证机关名称 {
			get {
				return this.m_发证机关名称;
			}
			set {
				this.m_发证机关名称 = value;
				this.m_Is发证机关名称Null = false;
			}
		}
		
		/// <summary>属性BSM</summary>
		[Member("BSM", "BSM", true, true, "BSM")]
		[Browsable(true)]
		[DisplayName("BSM")]
		[ReadOnly(false)]
		public int BSM {
			get {
				return this.m_BSM;
			}
			set {
				this.m_BSM = value;
				this.m_IsBSMNull = false;
				if ((this.OnOIDChanged != null)) {
					this.OnOIDChanged(this, null);
				}
			}
		}
		
		/// <summary>对象ID发生变化的时候触发的事件</summary>
		public event SuperORM.Attributes.OIDChangedHandler OnOIDChanged;
		
		/// <summary>属性改变的时候</summary>
		public event SuperORM.PropertyChangeHandler PropertyChanged;
		
		// 重载的方法，判断两个对象是否相等，判断条件是两个对象的主键值是否相等。
		public override bool Equals(object obj) {
			参数表 参数表 = ((参数表)(obj));
			if ((参数表.BSM == this.m_BSM)) {
				return true;
			}
			else {
				return false;
			}
		}
		
		/// <summary>判断某一个属性是否为空</summary>
		public override bool IsNull(string propname) {
			if (propname.Equals("发证机关编码")) {
				return this.m_Is发证机关编码Null;
			}
			if (propname.Equals("发证机关名称")) {
				return this.m_Is发证机关名称Null;
			}
			if (propname.Equals("BSM")) {
				return this.m_IsBSMNull;
			}
			return true;
		}
		
		/// <summary>将某个属性设置为空</summary>
		public override void SetNull(string propname) {
			if (propname.Equals("发证机关编码")) {
				this.m_Is发证机关编码Null = true;
				return;
			}
			if (propname.Equals("发证机关名称")) {
				this.m_Is发证机关名称Null = true;
				return;
			}
			if (propname.Equals("BSM")) {
				this.m_IsBSMNull = true;
				return;
			}
		}
	}
}
